for ($i=1;$i<=100;$i++) {
    $sum += $i;
    $sum_of_squares += $i**2;
}

print abs($sum**2-$sum_of_squares);
print "\n";